package com.hao.servlet;


import com.hao.Dao.userDao;
import com.hao.DaoImpl.userImpl;
import com.hao.entity.user;
import com.hao.Dao.productjsqDao;
import com.hao.DaoImpl.productjsqImpl;
import com.hao.entity.productjsq;


import javax.servlet.ServletException;
import javax.servlet.http.HttpServlet;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
import java.io.IOException;
import java.util.List;

/**
 * Created by Administrator on 2018/8/11.
 */
public class addfind extends HttpServlet {
    protected void doPost(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException {
        response.setContentType("text/html;charset=utf-8");
        request.setCharacterEncoding("utf-8");

        int uid=-1;
        int wpid=-1;
        userDao cc=new userImpl();
        List<user> list=cc.finduser(uid);
        request.setAttribute("listl", list);
        productjsqDao dd=new productjsqImpl();
        List<productjsq> lists=dd.finduser(wpid);
        request.setAttribute("listk", lists);

        request.getRequestDispatcher("productadd.jsp").forward(request, response);

    }

    protected void doGet(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException {
doPost(request,response);
    }
}
